From fb57a01c9033260ce1f73471aa587092638203f9 Mon Sep 17 00:00:00 2001 From: "kaf24@firebug.cl.cam.ac.uk" Date: Tue, 8 Nov 2005 12:25:09 +0100 Subject: [PATCH] Remove unused and unnecessary gnttab ioctl. Signed-off-by: Keir Fraser --- linux-2.6-xen-sparse/arch/xen/kernel/gnttab.c | 48 +------------------ 1 file changed, 1 insertion(+), 47 deletions(-) diff --git a/linux-2.6-xen-sparse/arch/xen/kernel/gnttab.c b/linux-2.6-xen-sparse/arch/xen/kernel/gnttab.c index 4c0a10541b..e996b9d832 100644 --- a/linux-2.6-xen-sparse/arch/xen/kernel/gnttab.c +++ b/linux-2.6-xen-sparse/arch/xen/kernel/gnttab.c @@ -337,53 +337,7 @@ gnttab_request_free_callback(struct gnttab_free_callback *callback, #ifdef CONFIG_PROC_FS static struct proc_dir_entry *grant_pde; - -static int -grant_ioctl(struct inode *inode, struct file *file, unsigned int cmd, - unsigned long data) -{ - int ret; - privcmd_hypercall_t hypercall; - - /* - * XXX Need safety checks here if using for anything other - * than debugging. - */ - return -ENOSYS; - - if ( cmd != IOCTL_PRIVCMD_HYPERCALL ) - return -ENOSYS; - - if ( copy_from_user(&hypercall, (void *)data, sizeof(hypercall)) ) - return -EFAULT; - - if ( hypercall.op != __HYPERVISOR_grant_table_op ) - return -ENOSYS; - -#ifdef __ia64__ - ret = HYPERVISOR_grant_table_op(hypercall.arg[0], (void *)hypercall.arg[1], hypercall.arg[2]); -#else - /* hypercall-invoking asm taken from privcmd.c */ - __asm__ __volatile__ ( - "pushl %%ebx; pushl %%ecx; pushl %%edx; " - "pushl %%esi; pushl %%edi; " - "movl 4(%%eax),%%ebx ;" - "movl 8(%%eax),%%ecx ;" - "movl 12(%%eax),%%edx ;" - "movl 16(%%eax),%%esi ;" - "movl 20(%%eax),%%edi ;" - "movl (%%eax),%%eax ;" - TRAP_INSTR "; " - "popl %%edi; popl %%esi; popl %%edx; popl %%ecx; popl %%ebx" - : "=a" (ret) : "0" (&hypercall) : "memory" ); -#endif - - return ret; -} - -static struct file_operations grant_file_ops = { - ioctl: grant_ioctl, -}; +static struct file_operations grant_file_ops; static int grant_read(char *page, char **start, off_t off, int count, int *eof, -- 2.30.2